package sample.user.web.controller;

import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

import sample.base.web.BaseWeb;
import sample.user.service.UserServiceAnnotation;
import sample.user.service.consumer.UserServiceConsumer;

@RestController
public class SeachController extends BaseWeb {
	
	private final Logger logger = LoggerFactory.getLogger(this.getClass());
	 
	@Autowired
	private UserServiceAnnotation userServiceAnnotation;
	@Autowired
	private UserServiceConsumer userServiceConsumer;
	
	@RequestMapping("/mapperAnnotation/select")
	public String mapperAnnotation() {
		logger.info(httpServletRequest.getRequestURI());
	
		return userServiceAnnotation.getUser();
	}
	
	
	@RequestMapping("/userConsumer/select")
	public String userConsumer() {
		logger.info(httpServletRequest.getRequestURI());
	
		return userServiceConsumer.getUser();
	}
}
